# $LastChangedDate: 2010-02-02 12:33:01 -0500 (Tue, 02 Feb 2010) $
# Author:	Jim E. Brooks  http://www.palomino3d.org

ROOT_DIR 	:= ../..
SRC_DIR     := src
OUT_DIR     := out
include $(ROOT_DIR)/tests/tools/GNUmakefile_defs
CXX			= g++
CXXFLAGS	= -Wall -O
TARGET_NAME	:= "shader tests"

ifeq ($(QUIET),1)
define COMPILE_TEST
	@echo Compiling shader test $(notdir $<)
	@$(CXX) -o $@ $< $(CXXFLAGS) $(LDFLAGS) $(SYS_LIBS)
endef
else
define COMPILE_TEST
	$(CXX) -o $@ $< $(CXXFLAGS) $(LDFLAGS) $(SYS_LIBS)
endef
endif

all: splash out/macro

.PHONY: splash
splash:
	@echo " "
	@echo "---- Building $(TARGET_NAME) ---- "
	@echo " "

out/macro: macro.cc
	@[ -d $(OUT_DIR) ] || mkdir $(OUT_DIR)
	$(COMPILE_TEST)

clean:
	@rm -rf core *.core core.* $(OUT_DIR)
